package com.SpringAndMybatis.Test;

import com.SpringAndMybatis.Impl.User;
import com.SpringAndMybatis.Mapper.UserMapper;

import java.util.List;

public class UserService {
    private UserMapper userMapper;

    public void setUserMapper(UserMapper userMapper) {
        this.userMapper = userMapper;
    }
    public void show(){
        List<User> users = userMapper.selectAll();
        for (User u:users){
            System.out.println(u);
        }
    }
}
